tools/xen-detect: fix printing xen version
authorKeir Fraser <keir.fraser@citrix.com>
Wed, 3 Feb 2010 09:42:45 +0000 (09:42 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Wed, 3 Feb 2010 09:42:45 +0000 (09:42 +0000)
check_for_xen() should return xen version rather than
boolean true if signature XenVMM is found.

Signed-off-by: Yu Zhiguo <yuzg@cn.fujitsu.com>
tools/misc/xen-detect.c

index 1a1607fa857f3ce8fdf53b1b33f88dcfeabd79b5..3e8f2d9f078bca669b929442ceb5ccfb31463fb4 100644 (file)
@@ -69,7 +69,7 @@ static int check_for_xen(int pv_context)
 
  found:
     cpuid(base + 1, &eax, &ebx, &ecx, &edx, pv_context);
-    return 1;
+    return eax;
 }
 
 static jmp_buf sigill_jmp;